package net.aizhuoyue.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import net.aizhuoyue.dao.StudentDao;
import net.aizhuoyue.entity.Student;
import net.aizhuoyue.service.StudentService;

/**
 * 学生信息Service实现类
 * @author Administrator
 *
 */
@Service("studentService")
public class StudentServiceImpl implements StudentService {
	@Resource
    private StudentDao studentDao;
	@Override
	public void save(Student student) {
		studentDao.save(student);
	}

	@Override
	public Student findById(Integer id) {
		return studentDao.findOne(id);
	}

	@Override
	public List<Student> list() {
		return studentDao.findAll();
	}

	@Override
	public void delete(Integer id) {
		studentDao.delete(id);
	}

}
